how can you solve questions on lcm and hcf